This forum is closed to new posts and
responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:
Thank you for your post and your recommendation. We resolved our problem, by essentially doing what you recommended. A code sample of our solution is shown below.
Thanks again,
KC
Code Sample:
Declarations
Dim gSession As NotesSession
Dim profsession As NotesSession
Dim profdb As NotesDatabase
Dim gDb As NotesDatabase
Dim profdoc As NotesDocument
Dim globalprofile As NotesDocument
Dim gUserProfile As NotesDocument
Dim profnam As NotesName
Dim client As Variant
Dim curid As String
Dim curdept As String
Dim curdeptvp As String
Dim curdeptsrvp As String
Dim curdepartmentmanagerid As String
Dim curdepartmentvpid As String
Dim curdepartmentsrvpid As String
Dim sessionXML As NotesSession
Dim gDomParser As NotesDOMParser
Dim domDoc As NotesDOMDocumentNode
Dim nodelist As NotesDOMNodeList
Dim parent As NotesDOMNode, child As NotesDOMNode
Dim value As String
Dim j As Integer, k As Integer
Dim qSoapRequest2 As String, qSoapResponse2 As String
Dim tempunderid As Variant
Dim tempunder1id As Variant
Dim undername As String
Dim under1name As String
Dim tempundername As String
Dim tempunder1name As String
Dim temp() As Variant
Dim tempcount As Integer
Dim tempA() As Variant
Dim tempAcount As Integer
Dim temp1() As Variant
Dim temp1count As Integer
Dim temp1A() As Variant
Dim temp1Acount As Integer
Dim adminid()As Variant
Dim adminidcount As Integer
Dim adminidexec()As Variant
Dim adminidexeccount As Integer
Dim prof_session As NotesSession
Dim prof_db As NotesDatabase
Dim prof_profdoc As NotesDocument
Dim profileswitch As String
'Profile Forms
Const gUserSettings = "UserSettings"
Sub Initialize
Set gSession = New NotesSession
Set gDb = gSession.CurrentDatabase
Set gUserProfile = gDb.GetProfileDocument(gUserSettings, gSession.UserName)
End Sub
Sub GetCurUserIDandDept()
On Error Resume Next
Dim rep1 As String, rep2 As String
Dim tmpResponse As String
Dim value As String
Dim j As Integer, k As Integer
Dim gItem As New NotesItem(gUserProfile, "DirectReportsIds", "")
'Get handle to DirectReportsIds and reset values
gItem.Values = ""
'Create Soap Client
On Error Goto errorHandler
Dim objHttp As Variant
Set objHttp = CreateObject("MSXML2.XMLHTTP.6.0")
'Call web service and parse response
Set gDomParser = gSession.createDOMParser(tmpResponse)
Call gDomParser.Parse
Set domDoc = gDomParser.Document
Set nodeList = domDoc.GetElementsByTagName("Employee")
'Error handling if nodeList is empty
If (nodeList.NumberOfEntries = 0) Then
Msgbox "No employee data was found.", 0, "Error"
End 'Stop all processing immediately
End If
For j = 1 To nodeList.NumberOfEntries
Set parent = nodeList.GetItem(j)
For k = 1 To parent.NumberOfChildNodes
If k = 1 Then
Set child = parent.FirstChild
Else
Set child = child.NextSibling
End If
'Allow for null values
If child.FirstChild.IsNull Then
value = ""
Else
value = child.FirstChild.NodeValue
End If
Select Case child.NodeName
Case "empid"
curid= value
Case "deptid"
curdept= value
End Select
Next k
Next j
errorHandler:
objHttp = Null
Resume Next
End Sub
Feedback response number WEBB86GRWY created by ~Rebecca Bregerokonyakoi on 06/16/2010